package com.goy.playground;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.widget.TextView;

public class TestActivity extends Activity {
	
	private TextView state;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_test);
		state = (TextView) findViewById(R.id.state);
		state.setText("onCreate");
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.activity_test, menu);
		return true;
	}
	
	@Override
	protected void onPause() {
		state.setText("onPause");
		super.onPause();
	}

	@Override
	protected void onResume() {
		state.setText("onResume");
		super.onResume();
	}

	@Override
	protected void onStart() {
		state.setText("onStart");
		super.onStart();
	}

	@Override
	protected void onStop() {
		state.setText("onStop");
		super.onStop();
	}

	public void onAgreeClick(View view) {
		Intent intent = new Intent(TestActivity.this, PortalActivity.class);
		
		startActivity(intent);
	}

}
